package com.ikas.ai.server.module.condition.model;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.ikas.ai.server.config.handler.ListLongHandler;
import com.ikas.ai.server.config.handler.MapVListStringHandler;
import lombok.Data;

import java.util.Date;
import java.util.List;
import java.util.Map;

/**
 * @Description: 工况步骤详情
 * @Author: qi.yilai
 * @Date: 2023/4/11 18:39
 * @Version: 1.0.0
 **/
@Data
@TableName(value = "t_work_condition_step_detail",autoResultMap = true)
public class WorkConditionStepDetail {

    private Long id;

    /**
     * 工况id
     */
    private Long wfId;

    /**
     * 步骤id
     */
    private Long stepId;

    private String meteName;

    private String meteCode;

    private String validMeteValue;

    /**
     * 子detailid集合
     */
    @TableField(typeHandler = ListLongHandler.class)
    private List<Long> subDetailIds;

    /**
     * 逻辑操作符（|| or &&）
     */
    private String subLogicalOperator;

    /**
     * 父detailId
     */
    private Long pDetailId;

    /**
     * 是否是叶子节点
     */
    private Boolean leaf;

    private Byte type;

    @TableField(typeHandler = MapVListStringHandler.class)
    private Map<String,List<String>> pMeteCode;

    private Integer labelType;

    private String label;

    private Integer updatePolicy;

    private Integer groupNo;

    private Long groupStepId;

    @TableField(exist = false)
    private String groupStep;

    private Integer sort;

    //测点值是否工况流程测点值先收到 0正常 1提前
    private Integer earlyCache;

    private Date createTime;

    private Date updateTime;

    private Long creator;
}
